MCPcopy Create free account
hub / github.com/ImageEngine/cortex / convertUsingNamespace

Function convertUsingNamespace

contrib/scripts/convertSceneC++.py:92–108  ·  view source on GitHub ↗
( lines )

Source from the content-addressed store, hash-verified

90 return newLines
91
92def convertUsingNamespace( lines ) :
93
94 haveScene = False
95 for line in lines :
96 if "IECoreScene" in line :
97 haveScene = True
98 break
99
100 if not haveScene :
101 return lines
102
103 for i, line in enumerate( lines ) :
104 if line == "using namespace IECore;\n" :
105 lines.insert( i + 1, "using namespace IECoreScene;\n" )
106 break
107
108 return lines
109
110def convertFile( filename ) :
111

Callers 1

convertFileFunction · 0.85

Calls 1

insertMethod · 0.80

Tested by

no test coverage detected