Advertisement
Hikigaya8man

git_change_01

May 24th, 2017
213
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. # Manual hunk edit mode -- see bottom for a quick guide
  2. @@ -19,12 +41,14 @@ struct stack_ctx *stack_init(int initial_stack_size)
  3. return ctx;
  4. }
  5.  
  6. +// Free inner data structures and stack's context.
  7. void stack_destroy(struct stack_ctx *ctx)
  8. {
  9. free(ctx->data);
  10. free(ctx);
  11. }
  12.  
  13. +// Push one number to stack
  14. void stack_push(struct stack_ctx *ctx, int num)
  15. {
  16. if (ctx->pointer == ctx->stack_size) {
  17. # ---
  18. # To remove '-' lines, make them ' ' lines (context).
  19. # To remove '+' lines, delete them.
  20. # Lines starting with # will be removed.
  21. #
  22. # If the patch applies cleanly, the edited hunk will immediately be
  23. # marked for staging. If it does not apply cleanly, you will be given
  24. # an opportunity to edit again. If all lines of the hunk are removed,
  25. # then the edit is aborted and the hunk is left unchanged.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement