Skip to content

Conversation

@troizet
Copy link
Collaborator

@troizet troizet commented Dec 1, 2025

In this PR:

  • Added folding for heredoc and nowdoc
  • Fixed test FoldingTest
  • Added new tests in FoldingTest

Example:

<?php

echo <<<HEREDOC
    Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
    Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
    Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
    Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
HEREDOC;


echo <<<'NOWDOC'
    Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
    Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
    Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.
    Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
NOWDOC;

Before:
before

After:
after

after_collapsed

^Add meaningful description above

Click to collapse/expand PR instructions

By opening a pull request you confirm that, unless explicitly stated otherwise, the changes -

  • are all your own work, and you have the right to contribute them.
  • are contributed solely under the terms and conditions of the Apache License 2.0 (see section 5 of the license for more information).

Please make sure (eg. git log) that all commits have a valid name and email address for you in the Author field.

If you're a first time contributor, see the Contributing guidelines for more information.

If you're a committer, please label the PR before pressing "Create pull request" so that the right test jobs can run.

PR approval and merge checklist:

  1. Was this PR correctly labeled, did the right tests run? When did they run?
  2. Is this PR squashed?
  3. Are author name / email address correct? Are co-authors correctly listed? Do the commit messages need updates?
  4. Does the PR title and description still fit after the Nth iteration? Is the description sufficient to appear in the release notes?

If this PR targets the delivery branch: don't merge. (full wiki article)

@troizet troizet added the PHP [ci] enable extra PHP tests (php/php.editor) label Dec 1, 2025
@troizet troizet requested review from junichi11 and tmysik December 1, 2025 05:48
@mbien mbien added the Editor label Dec 1, 2025
@mbien mbien added this to the NB29 milestone Dec 1, 2025
@troizet troizet force-pushed the folding_heredoc_nowdoc branch from a2fae5b to a09d1e5 Compare December 1, 2025 14:03
@troizet
Copy link
Collaborator Author

troizet commented Dec 1, 2025

@mbien Thanks for the tip. I've made the corrections.

Copy link
Member

@tmysik tmysik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your work.

@matthiasblaesing
Copy link
Contributor

@troizet the git commit message should have the structure:

  • first line is summary of the changes
  • empty line
  • detailed info about the changes (if necessary)

Would you mind updating to something along the lines of this?

Added folding for heredoc and nowdoc

Additionally:
- Fixed test FoldingTest
- Added new tests in FoldingTest

Additionaly:
- Fixed test FoldingTest
- Added new tests in FoldingTest
@troizet troizet force-pushed the folding_heredoc_nowdoc branch from a09d1e5 to c4fc922 Compare December 4, 2025 02:13
@troizet
Copy link
Collaborator Author

troizet commented Dec 4, 2025

@matthiasblaesing Updated the commit message.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Editor PHP [ci] enable extra PHP tests (php/php.editor)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants