Did you know ... Search Documentation:
Pack logtalk -- logtalk-3.77.0/manuals/_sources/faq/usability.rst.txt

.. This file is part of Logtalk https://logtalk.org/ SPDX-FileCopyrightText: 1998-2024 Paulo Moura <pmoura@logtalk.org> SPDX-License-Identifier: Apache-2.0

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

.. _faq_usability:

Usability

:(ref:[102, 97, 113, 95, 117, 115, 97, 98, 105, 108, 105, 116, 121, 95, 115, 104, 111, 114, 116, 99, 117, 116, 115])
:(ref:[102, 97, 113, 95, 117, 115, 97, 98, 105, 108, 105, 116, 121, 95, 101, 110, 115, 117, 114, 101, 95, 108, 111, 97, 100, 101, 100])
:(ref:[102, 97, 113, 95, 117, 115, 97, 98, 105, 108, 105, 116, 121, 95, 109, 97, 107, 101])
.. _faq_usability_shortcuts:

Is there a shortcut for compiling and loading source files?

Yes. With most backend Prolog compilers, you can use {File} as a shortcut for logtalk_load(File). For compiling and loading multiple files simply use {File1, File2, ...}. See the documentation of the :ref:predicates_logtalk_load_1 predicate for details.

.. _faq_usability_ensure_loaded:

Is there an equivalent directive to the ensure_loaded/1 Prolog directive?

You can use the goal logtalk_load(File, [reload(skip)]) to ensure that File is only loaded once. See the documentation of the :ref:predicates_logtalk_load_2 predicate for details.

.. _faq_usability_make:

Are there shortcuts for the make functionality?

Yes. With most backend Prolog compilers, you can use {*} as a shortcut for logtalk_make(all) to reload all files modified since last compiled and loaded, {!} as a shortcut for logtalk_make(clean) to delete all intermediate Prolog files generated by the compilation of Logtalk source files, {?} as a shortcut for logtalk_make(missing) to list missing entities and predicates, and {@} as a shortcut for logtalk_make(circular) to list circular references. See the documentation of the :ref:predicates_logtalk_make_1 predicate for details.