
set_flag(+Flag, ++Value)

   Set the flag Flag to the value Value.

Arguments
   Flag                Atom.
   Value               Atomic or compound term.

Type
   Development Environment and Global Settings

Description
    Used to set the environment flag Flag to the value Value.

    Refer to the specification of get_flag/2 for details about each flag.

    The current value(s) of a flag may be returned using get_flag/2.


Modes and Determinism
   set_flag(+, ++) is det

Modules
   This predicate is sensitive to its module context (tool predicate, see @/2).

Exceptions
     4 --- Flag and/or Value are not instantiated.
     5 --- Flag is neither an atom nor a variable.
     5 --- Value is not of the expected type.
     6 --- Flag and/or Value are out of range.
    30 --- Flag is a read-only flag.
   141 --- Unimplemented setting.

Examples
   
Set a simple option to a different value:
   ?- set_flag(gc, verbose).

   ?- set_flag(macro_expansion, off).

Add a value to a multi-valued option:
   ?- set_flag(syntax_option, read_floats_as_breals).

Remove a value from a multi-valued option:
   ?- set_flag(syntax_option, not read_floats_as_breals).

Modify the library path:
   ?- get_flag(library_path, OldPath),
      set_flag(library_path, ["/home/myuser/mylibs"|OldPath]).

Error:
   set_flag(X,a).                (Error  4)
   set_flag("a",x).              (Error  5)
   set_flag(blah, a).            (Error  6)
   set_flag(gc,fred).            (Error  6)
   set_flag(version,1).          (Error 30)


See Also
   get_flag / 2, set_prolog_flag / 2, env / 0, cd / 1, lib / 1, write_term / 3, syntax_option / 1
