An Ontario judge has ruled that it is unconstitutional to bar an accused from using the defence that he is too drunk to know what he is doing.

The drunk defence is normally not permitted for violent crimes. But on Thursday, the judge in an aggravated assault case declared the Criminal Code provision to be unconstitutional.

It is the first time a judge has allowed the drunkenness defence since 1995. That's when an amendment to the Criminal Code was passed because of a public outcry over its use in rape cases.

The ruling by Judge Patricia Wallace is not binding, but could be cited in other cases.

The case involved a Langton, Ontario man accused in the beating of another Langton man in July 1998. The victim remains in a chronic care facility and needs help with basic day-to-day tasks.

The accused's former girlfriend has testified that before the attack, the pair consumed two cases of beer and a bottle of tequila.

An expert on the effects of alcohol who testified at the trial Thursday said it is unlikely that someone could be so drunk that they have no idea what they are doing. Dr. Harold Kalant testified that someone may forget what they did after drinking too much, but would still be lucid at the time.