diff --git a/LICENSE b/LICENSE index 88dfc9249..086ba47f8 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,4 @@ -Copyright 2024 the authors. +Copyright 2025 the authors. Portions of setup.py, copyright 2016 Jason R Coombs . Permission is hereby granted, free of charge, to any person obtaining a diff --git a/docs/conf.py b/docs/conf.py index 3e2635bd7..7a4724aca 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -24,7 +24,7 @@ # Ultimately this will only appear on the page itself. The actual HTML title # will be simplified in post-processing. -hyrule_version = 'v0.7.0' +hyrule_version = 'v0.8.0' source_suffix = '.rst' master_doc = 'index' diff --git a/docs/tutorial.rst b/docs/tutorial.rst index 5d1723c89..e9c91b737 100644 --- a/docs/tutorial.rst +++ b/docs/tutorial.rst @@ -244,19 +244,22 @@ Define classes with :hy:func:`defclass`:: (defn get-x [self] self.x)) -Here we create a new instance ``fb`` of ``FooBar`` and access its attributes by -various means:: +Here we create a new instance ``fb`` of ``FooBar`` and access its attributes +with a :ref:`dotted identifier ` or :ref:`the dot macro +`:: (setv fb (FooBar 15)) - (print fb.x) ; => 15 - (print (. fb x)) ; => 15 - (print (.get-x fb)) ; => 15 - (print (fb.get-x)) ; => 15 + (print fb.x) ; => 15 + (print (. fb x)) ; => 15 + (print (. fb (get-x)) ; => 15 + (print (.get-x fb)) ; => 15 + (print (fb.get-x)) ; => 15 Note that syntax like ``fb.x`` and ``fb.get-x`` only works when the object being invoked (``fb``, in this case) is a simple variable name. To get an -attribute or call a method of an arbitrary form ``FORM``, you must use the -syntax ``(. FORM x)`` or ``(.get-x FORM)``, or call :py:func:`getattr`. +attribute or call a method of an arbitrary form ``FORM``, you must use one of +the other options, such as ``(. FORM x)`` or ``(.get-x FORM)``, or call +:py:func:`getattr`. Access an external module, whether written in Python or Hy, with :hy:func:`import`::