Handle result flags in visitor