call site 1 for path.local.__add__
path/testing/fscommon.py - line 240
238
239
240
241
   def test__getpymodule_c(self):
       otherdir = self.root.join('otherdir')
->     mod = otherdir.join('c.py')._getpymodule()
       assert mod.value == "got it"
path/local/local.py - line 438
435
436
437
438
439
440
441
   def _getpymodule(self):
       """resolve this path to a module python object. """
       if self.ext != '.c':
->         return super(LocalPath, self)._getpymodule()
       from py.__.misc.buildcmodule import make_module_from_c
       mod = make_module_from_c(self)
       return mod
path/common.py - line 380
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
   def _getpymodule(self):
       """resolve this path to a module python object. """
       modname = str(self)
       modname = modname.replace('.', self.sep)
       try:
           return sys.modules[modname]
       except KeyError:
->         co = self._getpycodeobj()
           mod = py.std.new.module(modname)
           mod.__file__ = PathStr(self)
           if self.basename == '__init__.py':
               mod.__path__ = [str(self.dirpath())]
           sys.modules[modname] = mod
           try: 
               exec co in mod.__dict__
           except: 
               del sys.modules[modname] 
               raise 
           return mod
path/local/local.py - line 450
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
   def _getpycodeobj(self):
       """ read the path and compile it to a code object. """
       dotpy = self.check(ext='.py')
       if dotpy:
           my_magic     = py.std.imp.get_magic()
           my_timestamp = int(self.mtime())
           if __debug__:
->             pycfile = self + 'c'
           else:
               pycfile = self + 'o'
           try:
               f = pycfile.open('rb')
               try:
                   header = f.read(8)
                   if len(header) == 8:
                       magic, timestamp = py.std.struct.unpack('<4si', header)
                       if magic == my_magic and timestamp == my_timestamp:
                           co = py.std.marshal.load(f)
                           path1 = co.co_filename
                           path2 = str(self)
                           if path1 == path2:
                               return co
                           try:
                               if os.path.samefile(path1, path2):
                                   return co
                           except (OSError,          # probably path1 not found
                                   AttributeError):  # samefile() not available
                               pass
               finally:
                   f.close()
           except py.error.Error:
               pass
       s = self.read(mode='rU') + '\n'
       codeobj = compile(s, str(self), 'exec', generators.compiler_flag)
       if dotpy:
           try:
               f = pycfile.open('wb')
               f.write(py.std.struct.pack('<4si', 'TEMP', -1))  # fixed below
               py.std.marshal.dump(codeobj, f)
               f.flush()
               f.seek(0)
               f.write(py.std.struct.pack('<4si', my_magic, my_timestamp))
               f.close()
           except py.error.Error:
               pass
       return codeobj