MCPcopy Create free account
hub / github.com/csyonghe/Spire / OpFunction

Method OpFunction

Source/SpireCore/SpirVCodeGen.cpp:804–818  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

802 streamHeader.Add(1);
803 }
804 void OpFunction(const int funcID, const int returnTypeID, const int functionTypeID)
805 {
806
807 sbTextFunctionHeader << LR"(%)" << funcID << LR"( = OpFunction )";
808 sbTextFunctionHeader << LR"(%)" << returnTypeID;
809 sbTextFunctionHeader << LR"( None)";
810 sbTextFunctionHeader << LR"( %)" << functionTypeID;
811 sbTextFunctionHeader << EndLine;
812
813 streamFunctionHeader.Add(54 + (5 << 16));
814 streamFunctionHeader.Add(returnTypeID);
815 streamFunctionHeader.Add(funcID);
816 streamFunctionHeader.Add(0); // function control - 0
817 streamFunctionHeader.Add(functionTypeID);
818 }
819 void OpFunctionParameter(const int paramID, const int typeID)
820 {
821 sbTextFunctionHeader << LR"(%)" << paramID << LR"( = OpFunctionParameter %)" << typeID << EndLine;

Callers 1

AddInstrFunctionMethod · 0.80

Calls 1

AddMethod · 0.45

Tested by

no test coverage detected