Browse Source

Template method PopBlock now returns the active block.

pull/220/merge
marcos henrich 12 years ago committed by triton
parent
commit
3237a7b421
  1. 6
      src/Generator/Generators/Template.cs

6
src/Generator/Generators/Template.cs

@ -291,10 +291,14 @@ namespace CppSharp.Generators @@ -291,10 +291,14 @@ namespace CppSharp.Generators
ActiveBlock = block;
}
public void PopBlock(NewLineKind newLineKind = NewLineKind.Never)
public Block PopBlock(NewLineKind newLineKind = NewLineKind.Never)
{
var block = ActiveBlock;
ActiveBlock.NewLineKind = newLineKind;
ActiveBlock = ActiveBlock.Parent;
return block;
}
public IEnumerable<Block> FindBlocks(int kind)

Loading…
Cancel
Save