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

False positive 1 space(s) after "-" with negative numbers #64

Closed
yguedidi opened this issue May 24, 2019 · 6 comments
Closed

False positive 1 space(s) after "-" with negative numbers #64

yguedidi opened this issue May 24, 2019 · 6 comments
Assignees
Labels
Milestone

Comments

@yguedidi
Copy link
Contributor

The following code gives a false positive:

{% set sliced = and foo|slice(-12, 12) %}

The error: ERROR There should be 1 space(s) after "-".

@OwlyCode OwlyCode added the bug label May 29, 2019
@OwlyCode OwlyCode self-assigned this May 29, 2019
@OwlyCode
Copy link
Collaborator

Hello! Thank you for reporting this. I'm currently in the middle of a partial rewrite that should fix a lot of false positives for spacing.

@OwlyCode
Copy link
Collaborator

This is on master, and scheduled for next beta version.

@OwlyCode OwlyCode added this to the 4.0.0 milestone Oct 14, 2019
@truls1502
Copy link

@oallain, is it already in the master-branch? What is the commit number for the changes?

@oallain
Copy link
Contributor

oallain commented Oct 14, 2019

@oallain, is it already in the master-branch? What is the commit number for the changes?

@truls1502 Sorry I don't understand your question, I haven't work on this issue.

@truls1502
Copy link

I am sorry, I tagged the wrong person. It was meant to @OwlyCode 😊

@oallain
Copy link
Contributor

oallain commented Oct 14, 2019

@truls1502 no problem ;)

So, i try it
With :

{% set sliced = and foo|slice(-12, 12) %}

friendsoftwig/twigcs:v3.1.3

ERROR There should be 1 space(s) after "-".

friendsoftwig/twigcs:dev-master
No error 😄

To conclude, yes, it's good on master 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants