interface
| 227 | |
| 228 | // interface |
| 229 | int asCModule::AddScriptSection(const char *in_name, const char *in_code, size_t in_codeLength, int in_lineOffset) |
| 230 | { |
| 231 | #ifdef AS_NO_COMPILER |
| 232 | UNUSED_VAR(in_name); |
| 233 | UNUSED_VAR(in_code); |
| 234 | UNUSED_VAR(in_codeLength); |
| 235 | UNUSED_VAR(in_lineOffset); |
| 236 | return asNOT_SUPPORTED; |
| 237 | #else |
| 238 | if( !m_builder ) |
| 239 | { |
| 240 | m_builder = asNEW(asCBuilder)(m_engine, this); |
| 241 | if( m_builder == 0 ) |
| 242 | return asOUT_OF_MEMORY; |
| 243 | } |
| 244 | |
| 245 | return m_builder->AddCode(in_name, in_code, (int)in_codeLength, in_lineOffset, (int)m_engine->GetScriptSectionNameIndex(in_name ? in_name : ""), m_engine->ep.copyScriptSections); |
| 246 | #endif |
| 247 | } |
| 248 | |
| 249 | // internal |
| 250 | void asCModule::JITCompile() |