Pārlūkot izejas kodu

Code style tweak to gcode.h

Scott Lahteine 8 gadus atpakaļ
vecāks
revīzija
33279a1e02
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. 1
    1
      Marlin/gcode.h

+ 1
- 1
Marlin/gcode.h Parādīt failu

133
     // Code is found in the string. If not found, value_ptr is unchanged.
133
     // Code is found in the string. If not found, value_ptr is unchanged.
134
     // This allows "if (seen('A')||seen('B'))" to use the last-found value.
134
     // This allows "if (seen('A')||seen('B'))" to use the last-found value.
135
     static bool seen(const char c) {
135
     static bool seen(const char c) {
136
-      char *p = strchr(command_args, c);
136
+      const char *p = strchr(command_args, c);
137
       const bool b = !!p;
137
       const bool b = !!p;
138
       if (b) value_ptr = DECIMAL_SIGNED(p[1]) ? &p[1] : NULL;
138
       if (b) value_ptr = DECIMAL_SIGNED(p[1]) ? &p[1] : NULL;
139
       return b;
139
       return b;

Notiek ielāde…
Atcelt
Saglabāt