Skip to content

Commit

Permalink
structured config docs import consistency (#834)
Browse files Browse the repository at this point in the history
Closes #833
  • Loading branch information
Jasha10 committed Dec 17, 2021
1 parent 207207a commit 3a77405
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/source/structured_config.rst
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,7 @@ supported by OmegaConf (``int``, ``float``. ``bool``, ``str``, ``Enum`` or Struc

.. doctest::

>>> from dataclasses import dataclass, field
>>> from typing import List, Tuple
>>> @dataclass
... class User:
Expand Down Expand Up @@ -246,6 +247,7 @@ as arbitrary Structured configs)

.. doctest::

>>> from dataclasses import dataclass, field
>>> from typing import Dict
>>> @dataclass
... class DictExample:
Expand Down Expand Up @@ -385,6 +387,8 @@ Frozen dataclasses and attr classes are supported via OmegaConf :ref:`read-only-

.. doctest::

>>> from dataclasses import dataclass, field
>>> from typing import List
>>> @dataclass(frozen=True)
... class FrozenClass:
... x: int = 10
Expand Down

0 comments on commit 3a77405

Please sign in to comment.