12.4.14 String buffering
All Application Manual Name SummaryHelp

  • Documentation
    • Reference manual
      • Foreign Language Interface
        • The Foreign Include File
          • String buffering
            • PL_STRINGS_MARK()
            • PL_STRINGS_RELEASE()
    • Packages
Availability:C-language interface function
void PL_STRINGS_MARK()
void PL_STRINGS_RELEASE()
These macros must be paired and create a C block ({...}). Any string created using BUF_STACK after PL_STRINGS_MARK() is released by the corresponding PL_STRINGS_RELEASE(). These macros should be used like below. Note that strings returned by any of the Prolog functions between this pair may be invalidated.
  ...
  PL_STRINGS_MARK();
    <operations involving strings>
  PL_STRINGS_RELEASE();
  ...