MCPcopy Index your code
hub / github.com/Nuitka/Nuitka / __init__

Method __init__

nuitka/nodes/ModuleNodes.py:261–313  ·  view source on GitHub ↗
(self, module_name, reason, is_top, mode, future_spec, source_ref)

Source from the content-addressed store, hash-verified

259 named_children = ("body|statements_or_none+setter", "functions|tuple+setter")
260
261 def __init__(self, module_name, reason, is_top, mode, future_spec, source_ref):
262 PythonModuleBase.__init__(
263 self,
264 module_name=module_name,
265 reason=reason,
266 source_ref=source_ref,
267 )
268
269 ClosureGiverNodeMixin.__init__(
270 self,
271 name=module_name.getBasename(),
272 code_prefix="module",
273 )
274
275 ModuleChildrenHavingBodyOptionalStatementsOrNoneFunctionsTupleMixin.__init__(
276 self,
277 body=None, # delayed
278 functions=(),
279 )
280
281 MarkNeedsAnnotationsMixin.__init__(self)
282
283 EntryPointMixin.__init__(self)
284
285 self.is_top = is_top
286
287 self.mode = mode
288
289 self.variables = {}
290
291 # Functions that have been used.
292 self.active_functions = OrderedSet()
293
294 # Functions that should be visited again.
295 self.visited_functions = set()
296
297 self.cross_used_functions = OrderedSet()
298
299 self.used_modules = OrderedSet()
300
301 # Often "None" until tree building finishes its part.
302 self.future_spec = future_spec
303
304 # The source code of the module if changed or not from disk.
305 self.source_code = None
306
307 self.module_dict_name = "globals_%s" % (self.getCodeName(),)
308
309 self.locals_scope = getLocalsDictHandle(
310 self.module_dict_name, "module_dict", self
311 )
312
313 self.used_modules = OrderedSet()
314
315 @staticmethod
316 def isCompiledPythonModule():

Callers

nothing calls this directly

Calls 5

getCodeNameMethod · 0.95
OrderedSetClass · 0.90
getLocalsDictHandleFunction · 0.85
getBasenameMethod · 0.80
__init__Method · 0.45

Tested by

no test coverage detected