Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Comment not printed error because of echo shorthand #2413

Open
p0psicles opened this issue Jan 16, 2025 · 0 comments
Open

Comment not printed error because of echo shorthand #2413

p0psicles opened this issue Jan 16, 2025 · 0 comments

Comments

@p0psicles
Copy link

@prettier/plugin-php v0.22.2
Playground link

Input:

<?php
/**
 * Tweakwise & Emico (https://www.tweakwise.com/ & https://www.emico.nl/) - All Rights Reserved
 *
 * @copyright Copyright (c) 2017-2017 Tweakwise.com B.V. (https://www.tweakwise.com)
 * @license   http://opensource.org/licenses/osl-3.0.php  Open Software License (OSL 3.0)
 */

// phpcs:disable PHPCompatibility.Miscellaneous.RemovedAlternativePHPTags.MaybeASPOpenTagFound
?>

<script id="autocomplete-item-template" type="text/x-magento-template" data-url="<?= $block->getAjaxUrl() ?>">
</script>

<?php
    // phpcs:enable PHPCompatibility.Miscellaneous.RemovedAlternativePHPTags.MaybeASPOpenTagFound
?>

Output:

Comment "// phpcs:enable PHPCompatibility.Miscellaneous.RemovedAlternativePHPTags.MaybeASPOpenTagFound" was not printed. Please report this error!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant