# subdir/subdir_b/utils

Theme:

- Index

Search:
Group by:

This is a description of the utils module.

Links work:

- other module: iterators (not in this dir, just an example)
- internal: fn2(x)
- internal included from another module: funWithGenerics*[T, U: SomeFloat](a: T, b: U).

# This is now a header

## Next header

### And so on

# More headers

###### Up to level 6

1. An enumeration
2. Second idea here.

More text.

1. Other case value
2. Second case.

Ref group fn2 or specific function like fn2() or fn2( int ) or fn2(int, float).

Ref generics like this: binarySearch or binarySearch(openArray[T], K, proc (T, K)) or proc binarySearch(openArray[T], K, proc (T, K)) or in different style: proc binarysearch(openarray[T], K, proc(T, K)). Can be combined with export symbols and type parameters: binarysearch*[T, K](openArray[T], K, proc (T, K)). With spaces binary search.

Note that `proc` can be used in postfix form: binarySearch proc.

Ref. type like G and type G and G[T] and type G*[T].

Group ref. with capital letters works: fN11 or fn11

Ref. [] is the same as proc `[]`(G[T]) because there are no overloads. The full form: proc `[]`*[T](x: G[T]): TRef. []= aka `[]=`(G[T], int, T).Ref. $ aka proc $ or proc `$`.Ref. $(a: ref SomeType).Ref. foo_bar aka iterator foo_bar_.Ref. fn[T; U,V: SomeFloat]().Ref. 'big or func `'big` or `'big`(string).

# Pandoc Markdown

Now repeat all the auto links of above in Pandoc Markdown Syntax.

Ref group fn2 or specific function like fn2() or fn2( int ) or fn2(int, float).

Ref generics like this: binarySearch or binarySearch(openArray[T], K, proc (T, K)) or proc binarySearch(openArray[T], K, proc (T, K)) or in different style: proc binarysearch(openarray[T], K, proc(T, K)). Can be combined with export symbols and type parameters: binarysearch*[T, K](openArray[T], K, proc (T, K)). With spaces binary search.

Note that `proc` can be used in postfix form: binarySearch proc.

Ref. type like G and type G and G[T] and type G*[T].

Group ref. with capital letters works: fN11 or fn11

Ref. `[]` is the same as proc `[]`(G[T]) because there are no overloads. The full form: proc `[]`*[T](x: G[T]): T Ref. `[]=` aka `[]=`(G[T], int, T). Ref. $ aka proc $ or proc `$`. Ref. $(a: ref SomeType). Ref. foo_bar aka iterator foo_bar_. Ref. fn[T; U,V: SomeFloat](). Ref. 'big or func `'big` or `'big`(string).

## Link name syntax

Pandoc Markdown has synax for changing text of links: Ref. this proc or another symbol.

## Symbols documentation

Let us repeat auto links from symbols section below:

There is also variant f(G[string]). See also f(G[int]).

# Types

    G[T] = object

    SomeType = enum
      enumValueA, enumValueB, enumValueC

# Procs

    proc `$`[T](a: G[T]): string

    proc `$`[T](a: ref SomeType): string

    func `'big`(a: string): SomeType {....raises: [], tags: [], forbids: [].}

    proc `[]`[T](x: G[T]): T

    proc `[]=`[T](a: var G[T]; index: int; value: T)

    proc binarySearch[T, K](a: openArray[T]; key: K;
                            cmp: proc (x: T; y: K): int {.closure.}): int

    proc f(x: G[int]) {....raises: [], tags: [], forbids: [].}

  There is also variant f(G[string])

    proc f(x: G[string]) {....raises: [], tags: [], forbids: [].}

  See also f(G[int]).

    proc fn[T; U, V: SomeFloat]()

    proc fn2() {....raises: [], tags: [], forbids: [].}

  comment

    proc fn2(x: int) {....raises: [], tags: [], forbids: [].}

  fn2 comment

    proc fn2(x: int; y: float) {....raises: [], tags: [], forbids: [].}

    proc fn2(x: int; y: float; z: float) {....raises: [], tags: [], forbids: [].}

    proc fn3(): auto {....raises: [], tags: [], forbids: [].}

  comment

    proc fn4(): auto {....raises: [], tags: [], forbids: [].}

  comment

    proc fn5() {....raises: [], tags: [], forbids: [].}

  comment

    proc fn6() {....raises: [], tags: [], forbids: [].}

  comment

    proc fn7() {....raises: [], tags: [], forbids: [].}

  comment

    proc fn8(): auto {....raises: [], tags: [], forbids: [].}

  comment

    func fn9(a: int): int {....raises: [], tags: [], forbids: [].}

  comment

    func fn10(a: int): int {....raises: [], tags: [], forbids: [].}

  comment

    func fN11() {....raises: [], tags: [], forbids: [].}

    func fN11(x: int) {....raises: [], tags: [], forbids: [].}

    proc funWithGenerics[T, U: SomeFloat](a: T; b: U)

    proc someType(): SomeType {....raises: [], tags: [], forbids: [].}

  constructor.

# Iterators

    iterator fooBar(a: seq[SomeType]): int {....raises: [], tags: [], forbids: [].}

# Templates

    template aEnum(): untyped

    template bEnum(): untyped

    template fromUtilsGen(): untyped

  should be shown in utils.html only

  Example:

      discard "should be in utils.html only, not in module that calls fromUtilsGen"

  ditto