Guest User

Untitled

a guest
Feb 21st, 2018
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.36 KB | None | 0 0
  1. class Example
  2. inline do |builder|
  3. builder.c %q{
  4. char *cs_fast(char *s1, char *s2) {
  5. char *start = s1;
  6. while (*s1 && *s2 && (*++s1 == *++s2));
  7. if ((*s1 != 0 && *s1 != 47) || (*s2 != 0 && *s2 != 47)) {
  8. while(*--s1 != 47);
  9. }
  10. if (s1-start <= 1) { *s1++; } // correction for '/'
  11. *s1 = 0;
  12. return s1;
  13. }
  14. }
  15. end
  16. end
Add Comment
Please, Sign In to add comment