---
spec: JVMS
title: "The Java Virtual Machine Specification"
edition: "Java SE 23 Edition"
java_version: 23
chapter: "Chapter 4. The class File Format"
section: "4.10.1.9.dneg"
heading: "dneg"
parent: "4.10.1.9. Type Checking Instructions"
source: https://docs.oracle.com/javase/specs/jvms/se23/html/jvms-4.html#jvms-4.10.1.9.dneg
id: "4.10.1.9.dneg"
url: https://jvm.obfuscated.software/jvms/se23/4.10.1.9.dneg.html
raw: https://jvm.obfuscated.software/jvms/se23/4.10.1.9.dneg.md
---

# dneg

A *dneg* instruction is type safe iff there is a type matching `double` on the incoming operand stack. The *dneg* instruction does not alter the type state.

```
instructionIsTypeSafe(dneg, Environment, _Offset, StackFrame,
                      NextStackFrame, ExceptionStackFrame) :-
    validTypeTransition(Environment, [double], double,
                        StackFrame, NextStackFrame),
    exceptionStackFrame(StackFrame, ExceptionStackFrame).
```
