MCPcopy Index your code
hub / github.com/nodejs/node / derived

Method derived

tools/inspector_protocol/jinja2/runtime.py:268–277  ·  view source on GitHub ↗

Internal helper function to create a derived context. This is used in situations where the system needs a new context in the same template that is independent.

(self, locals=None)

Source from the content-addressed store, hash-verified

266 'StopIteration exception')
267
268 def derived(self, locals=None):
269 """Internal helper function to create a derived context. This is
270 used in situations where the system needs a new context in the same
271 template that is independent.
272 """
273 context = new_context(self.environment, self.name, {},
274 self.get_all(), True, None, locals)
275 context.eval_ctx = self.eval_ctx
276 context.blocks.update((k, list(v)) for k, v in iteritems(self.blocks))
277 return context
278
279 def _all(meth):
280 proxy = lambda self: getattr(self.get_all(), meth)()

Callers

nothing calls this directly

Calls 4

get_allMethod · 0.95
new_contextFunction · 0.70
updateMethod · 0.65
listFunction · 0.50

Tested by

no test coverage detected