• Places
    • Home
    • Graphs
    • Prefixes
  • Admin
    • Users
    • Settings
    • Plugins
    • Statistics
  • Repository
    • Load local file
    • Load from HTTP
    • Load from library
    • Remove triples
    • Clear repository
  • Query
    • YASGUI SPARQL Editor
    • Simple Form
  • Help
    • Documentation
    • Tutorial
    • Roadmap
    • HTTP Services
  • Login

4.22 Analysing and Constructing Atoms
AllApplicationManualNameSummaryHelp

  • Documentation
    • Reference manual
      • Built-in Predicates
        • Analysing and Constructing Atoms
          • atom_codes/2
          • atom_chars/2
          • char_code/2
          • number_chars/2
          • number_codes/2
          • atom_number/2
          • name/2
          • term_to_atom/2
          • atom_to_term/3
          • atom_concat/3
          • atomic_concat/3
          • atomic_list_concat/2
          • atomic_list_concat/3
          • atom_length/2
          • atom_prefix/2
          • sub_atom/5
          • sub_atom_icasechk/3
    • Packages
Availability:built-in
[commons]atomic_list_concat(+List, +Separator, -Atom)
Creates an atom just like atomic_list_concat/2, but inserts Separator between each pair of inputs. For example:
?- atomic_list_concat([gnu, gnat], ', ', A).

A = 'gnu, gnat'

The SWI-Prolog version of this predicate can also be used to split atoms by instantiating Separator and Atom as shown below. We kept this functionality to simplify porting old SWI-Prolog code where this predicate was called concat_atom/3. When used in mode (-,+,+), Separator must be a non-empty atom. See also split_string/4.

?- atomic_list_concat(L, -, 'gnu-gnat').

L = [gnu, gnat]
ClioPatria (version V3.1.1-51-ga0b30a5)