Skip to content

Commit

Permalink
fix: removing *ENDIF
Browse files Browse the repository at this point in the history
  • Loading branch information
clatapie committed Jan 9, 2025
1 parent 895fe32 commit a13ddda
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 26 deletions.
1 change: 0 additions & 1 deletion doc/source/mapdl_commands/apdl/process_controls.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,5 @@ ProcessControls
:toctree: _autosummary


ProcessControls.endif
ProcessControls.starexit
ProcessControls.wait
12 changes: 6 additions & 6 deletions src/ansys/mapdl/core/_commands/apdl/macro_files.py
Original file line number Diff line number Diff line change
Expand Up @@ -544,11 +544,11 @@ def msg(
Enhanced descriptions may also be used: InformalTables need to be added.
Do not begin :ref:`msg` format lines with ``\*IF``, ``\*ELSE``, ``\*ELSEIF``, or :ref:`endif`. If
the last nonblank character of the message format is an ampersand (&), a second line will also be
read as a continuation of the format. Up to nine continuations (ten total lines) may be read. If
normal descriptions are used, then consecutive blanks are condensed into one blank upon output, and
a period is appended. Up to ten lines of output of 72 characters each may be produced (using the %/
Do not begin :ref:`msg` format lines with ``\*IF``, ``\*ELSE``, ``\*ELSEIF``, or ``\*ENDIF``. If the
last nonblank character of the message format is an ampersand (&), a second line will also be read
as a continuation of the format. Up to nine continuations (ten total lines) may be read. If normal
descriptions are used, then consecutive blanks are condensed into one blank upon output, and a
period is appended. Up to ten lines of output of 72 characters each may be produced (using the %/
descriptor). Two examples follow.
Here is an example of the :ref:`msg` command and a format to print a message with two integer values
Expand Down Expand Up @@ -616,7 +616,7 @@ def end(self, **kwargs):
Notes
-----
Closes a file opened with :ref:`create` . The :ref:`end` command is an 8-character command (to
differentiate it from :ref:`endif` ). If you add commented text on that same line but do not allow
differentiate it from ``\*ENDIF`` ). If you add commented text on that same line but do not allow
enough spaces between :ref:`end` and the "!" that indicates the comment text, the :ref:`end` will
attempt to interpret the "!" as the 8th character and will fail.
Expand Down
19 changes: 0 additions & 19 deletions src/ansys/mapdl/core/_commands/apdl/process_controls.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,25 +45,6 @@ def wait(self, dtime: str = "", **kwargs):
command = f"/WAIT,{dtime}"
return self.run(command, **kwargs)

def endif(self, **kwargs):
r"""Ends an if-then-else.
Mechanical APDL Command: `\*ENDIF <https://ansyshelp.ansys.com/Views/Secured/corp/v232/en//ans_cmd/Hlp_C_ENDIF.html>`_
Notes
-----
Required terminator for the if-then-else construct. See ``\*IF`` for details.
If a batch input stream hits an end-of-file during a false ``\*IF`` condition, the analysis will not
terminate normally. You will need to terminate it externally (use either the Linux "kill" function
or the Windows task manager). The :ref:`endif` command must appear on the same file as the ``\*IF``
command, and all six characters must be input.
This command is valid in any processor.
"""
command = "*ENDIF"
return self.run(command, **kwargs)

def starexit(self, **kwargs):
r"""Exits a do-loop.
Expand Down

0 comments on commit a13ddda

Please sign in to comment.