5.2.5 Predicates to support adapting code for double quoted strings
AllApplicationManualNameSummaryHelp

  • Documentation
    • Reference manual
      • SWI-Prolog extensions
        • The string type and its double quoted syntax
          • Predicates to support adapting code for double quoted strings
            • list_strings/0
            • string_predicate/1
            • valid_string_goal/1
    • Packages
Sourcecheck:valid_string_goal(:Goal)
Declare that calls to Goal are safe. The module qualification is the actual module in which Goal is defined. For example, a call to format/3 is resolved by the predicate system:format/3. and the code below specifies that the second argument may be a string (system predicates that accept strings are defined in the library).
:- multifile check:valid_string_goal/1.

check:valid_string_goal(system:format(_,S,_)) :- string(S).