Giter VIP home page Giter VIP logo

normez's People

Contributors

arcln avatar hadrienblanc avatar hapique avatar nwmqpa avatar ostefanini avatar phil-chp avatar rajiska avatar ronanboiteau avatar therosbif avatar xephi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

normez's Issues

Misplaced space(s) around '++' sign and Wrong Tabulation in Makefile

Hello,

When i make nb++ for example, but NormEZ tells me that I have misplaced space(s) around '++' sign, but only there aren't misplaced space(s) around this with this code as for example:
if (test_neg1 == 1) {
my_putchar('-');
nb1++;
nb2++;
}

And in Makefile, there are tabulation, but NormEZ wait for spaces

Failed to detect when body of function > 20 lines

NormEZ did not warn about the length of this function, very sad

int	my_getnbr(char *str)
{
    int negative_multiplier;
    unsigned long long int storage;

    negative_multiplier = 1;
    storage = 0;
    while (*str && *str != '\0' && (*str == '+' || *str == '-')){
        if (*str == '-') negative_multiplier *= -1;
        str++;
    }
    while (*str && *str != '\0' && (*str >= '0' && *str <= '9')){
        if (storage > 214748364){
            return 0;
        }
        storage = storage*10 + *str-48;
        str++;
    }
    if (negative_multiplier == -1 && storage > 2147483648){
        return 0;
    } else if (negative_multiplier == 1 && storage > 2147483647){
        return 0;
    }
    storage *= negative_multiplier;
    return (storage);
}

Failed to detect missplaced curly bracket

Actually missplaced curly brackets are not detected.
According to the L4 rule :

"Opening curly brackets should be at the end of their line, except for functions where they must be placed alone on their line."

in this test case :

int main(void) {
----if (1)
----{
--------return (1);
----}
----return (0);
}

missplaced curly bracket are not detected for the function AND the if statement.

Cheers,

NormEZ C++

Salut
ร€ quand la version pour la nouvelle norme c++?
ca pourrait interresser beaucoup de 2nde annee ^^
Merci!

Misplaced space(s) around '|' sign.

Hi, with this kind of code:

my_putchar('|');

I get this error:

Misplaced space(s) around '|' sign.

You should consider avoid this warning when there are quotes around the pipe. :)

Couple problems

Hello, i've figured out four small problems in your Norme.
First of, when -- (Or ++, or ^ ...) is surrended by other chars (in a commentary ofc), your Norme detect it as an error.
The second that I'm running in, is the use of this sentence

var[0]++;

In third position, the printf function, while being detected as an error, enclose also the my_printf function which is also declared as an error, as every other line containing the word printf inside, commented or not.
Which, while being correct, is detcted as an error.
Finally, the last error that happens to me is the several assignements on the same line that happens with :

write(2, ": \033[1;36m", 9);

Invalid Bytes sequence..

NormEZ.rb:293:in 'block in check_trailing_spaces_tabs': invalid byte sequence in UTF-8 (ArgumentError)
from NormEZ.rb:292:in 'each_line'
from NormEZ.rb:292:in 'check_trailing_spaces_tabs'
from NormEZ.rb:126:in 'check_file'
from NormEZ.rb:122:in 'initialize'
from NormEZ.rb:542:in 'new'
from NormEZ.rb:542:in '<main>'

What is it?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.