Skip to content

Instantly share code, notes, and snippets.

@maks-rafalko
Last active October 15, 2017 09:48
Show Gist options
  • Save maks-rafalko/fc0a3770b8cba7ca0bd931309441c227 to your computer and use it in GitHub Desktop.
Save maks-rafalko/fc0a3770b8cba7ca0bd931309441c227 to your computer and use it in GitHub Desktop.
// 1. spaceship operator
- $a <=> $b;
+ $b <=> $a;
// 2. break; <-> continue;
foreach (...) {
- break;
+ continue;
}
// 3. zero iteration
- foreach ($someVar as ...) {
+ foreach ([] as ...) {
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment